/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.ventas.dao;

import java.sql.Connection;
import java.sql.DriverManager;

/**
 *
 * @author Desarrollador
 */
public class Conexion {
    public static Connection getConexion() throws Exception{
        Connection cn = null;
    
        try {
            Class.forName("com.mysql.jdbc.Driver");
            cn = DriverManager.getConnection("jdbc:mysql://localhost/dbdaw02ventas", "root", "system123");
        } catch (Exception e) {
            System.out.println("Error conexion "+e.getMessage());
        }
        return cn;
    }
}
